home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
vol_400
/
428_02
/
examples
/
msgbox.c
< prev
next >
Wrap
C/C++ Source or Header
|
1994-03-13
|
528b
|
28 lines
/*
** MSGBOX.C: Takes action based on the user's response to
** a message box.
*/
#include <pictor.h>
COLORSTRUCT msgcolors = {
foreback(BOLD+WHITE,RED),
foreback(BOLD+YELLOW,RED),
foreback(BLACK,WHITE),
foreback(BOLD+WHITE,WHITE)
};
void main()
{
/* initialize library */
initvideo();
/* clear screen if user selects yes */
if(messagebox("Do you want the screen cleared?",
"Question",MB_YESNO,&msgcolors)) {
vcolor(foreback(WHITE,BLACK));
cls();
}
}